http = require "http"
map = require('through2-map')

port = 8000
file_path = process.argv[2]

server = http.createServer (req, res) ->
  return res.end("need post") if req.method != "POST"
  req.pipe(map (chunk) ->
    chunk.toString().toUpperCase()
  ).pipe(res)

server.listen(port)
